﻿@model FogBugzPd.Web.Models.Project.DashboardViewModel
@{
    ViewBag.Title = "Dashboard";
    Layout = "~/Views/Project/_Layout.cshtml";
}

@section Js
{
	<script type="text/javascript">
		$(document).ready(function () {
			$("#loader").height($("#project-content").height());
			if ($("#loader").height() == 0)
				$("#loader").height(200);
			$("#loader").show();

			$.post(resolveUrl("~/Project/AsyncDashboard"),
            {
            	projectId: "@Model.ProjectId",
                milestoneId: "@Model.MilestoneId",
            	subProjectParentCaseId: "@Model.SubProjectParentCaseId"
            },
            function (result) {
            	$("#dashboard-async-content").empty();
            	$("#dashboard-async-content").html(result);
            	$("#dashboard-async-content").show();
            	$("#loader").hide();
            }, "HTML");
		});
	</script>
}

<div id="dashboard-async-content">
</div>

